<template>
    <h3>Child</h3>
    <p>{{ golabTitle }}</p>
    <hr>
    <p>{{ title }}</p>
    <hr>
    <p>{{ fullMessage }}</p>
</template>
<script>
export default {
    inject: ['title', 'golabTitle'],
    data() {
        return {
            // 使用来自注入的 title 值
            fullMessage: this.title
        }
    },
    created() {
        console.log(this.title)
    }
}
</script>